import { RouteConfig } from "vue-router";
import Layout from "@/layout/index.vue";

const resourceRouter: RouteConfig = {
  path: "/client",
  component: Layout,
  redirect: "/client/clientList",
  name: "Client",
  meta: {
    title: "clientManage",
    routerRuleName: "Client"
  },
  children: [
    {
      path: "clientList",
      component: () => import("@/views/cloudClient/list/index.vue"),
      name: "ClientList",
      meta: {
        title: "clientList",
        noCache: true,
        routerRuleName: "ClientList"
      }
    },
    {
      path: "clientVersion",
      component: () => import("@/views/cloudClient/version/index.vue"),
      name: "ClientVersion",
      meta: {
        title: "clientVersion",
        noCache: true,
        authrole: 'system_admin',
        routerRuleName: "ClientVersion"
      }
    },
    {
      path: "versionLog",
      component: () => import("@/views/cloudClient/versionLog/index.vue"),
      name: "VersionLog",
      meta: {
        title: "versionLog",
        noCache: true,
        authrole: 'system_admin',
        routerRuleName: "VersionLog"
      },
    },
    {
      path: "versionLogList",
      component: () => import("@/views/cloudClient/versionLog/versionLogList.vue"),
      name: "versionLogList",
      meta: {
        title: "versionLogList",
        noCache: true,
        authrole: 'system_admin',
        hidden: true,
        type: "/client/versionLog"
      }
    },
    // {
    //   path: "remoteClient",
    //   component: () => import("@/views/cloudClient/list/components/remoteClient.vue"),
    //   name: "RemoteClient",
    //   meta: {
    //     title: "remoteClient",
    //     noCache: true,
    //     hidden: true,
    //   }
    // }
  ]
};

export default resourceRouter;
